home *** CD-ROM | disk | FTP | other *** search
/ Aminet 24 / Aminet 24 (1998)(GTI - Schatztruhe)[!][Apr 1998].iso / Aminet / comm / ambos / APOnlineStatus.lha / OnlineStatus_Install / InstallAutoPOINT < prev    next >
Text File  |  1997-12-31  |  4KB  |  117 lines

  1. ;*******************************************************************
  2. ; Installer, für ein AutoPOINT
  3. ;*******************************************************************
  4.  
  5. ;*******************************************************************
  6. ; Definitionen
  7. ;*******************************************************************
  8. (set #version "1.0")
  9. (set #changefile "Changes_971022")
  10. (set #programm "AP_OnlineStatus")
  11. (set #install 1)
  12. (set #updatetxt "Installieren ")
  13.  
  14. ;*******************************************************************
  15. ; Wenn das Verzeichnis BBS:AutoPOINTS noch nicht existiert, wird
  16. ; es angelegt.
  17. ;*******************************************************************
  18. (if (< (exists "bbs:AutoPOINTs") 1)
  19.     (
  20.         (makedir "bbs:AutoPOINTs")
  21.     )
  22. )
  23.  
  24. ;*******************************************************************
  25. ; Start
  26. ;*******************************************************************
  27. (message (cat "\nAutoPOINT-Programm `" #programm "` V" #version 
  28.               "\n~~~~~~~~~~~~~~~~~~~~~~~~\n"
  29.               "für das Mailboxprogramm AmBoS\n\n"
  30.               #programm "\n\nvon Gerhard Lühning"
  31.          )
  32. )
  33. (welcome)
  34.  
  35. ;*******************************************************************
  36. ; Pfad abfragen
  37. ;*******************************************************************
  38. (set #zielverzeichnis "bbs:AutoPOINTs")
  39. (set #zielverzeichnis    (askdir 
  40.                                                 (prompt (cat "Geben Sie bitte an, in welchen Verzeichnis sich das " #programm "-VERZEICHNIS befindet."))
  41.                                                 (help   (cat "Wenn Sie das " #programm " noch nicht installiert haben, wählen Sie das Verzeichnis, wo das Programm Verzeichnis installiert werden soll (z.B. BBS:AutoPOINTS). Es wird ein Verzeichnis mit den Namen `" #programm " `angelegt"))
  42.                                                 (default #zielverzeichnis)
  43.                                             )
  44. )
  45.  
  46. ;*******************************************************************
  47. ;  Existiert bereits das Zielverzeichnis mit Programm ?
  48. ;  -> dann nur Update und kein neues anlinken am Module
  49. ;*******************************************************************
  50. (if (= (exists (cat #zielverzeichnis "/" #programm)) 2)
  51.     (
  52.         (if (= (exists (cat #zielverzeichnis "/" #programm "/" #programm)) 1)
  53.             (
  54.                 (set #install 0)
  55.                 (set #updatetxt "Updaten ")
  56.             )        
  57.         )
  58.     )
  59. )
  60.  
  61. ;*******************************************************************
  62. ;  Letzte Abfrage und dann Programm-Dateien kopieren
  63. ;*******************************************************************
  64. (set #copyprg 
  65.     (askchoice
  66.         (choices (cat #updatetxt #programm) (cat "Nicht " #updatetxt #programm))
  67.         (prompt "Wollen Sie das AutoPOINT-Prgogramm installieren?")
  68.         (help "Dieses ist ein OnlineStatus-AutoPOINT-Prg. welches dem Point seine Onlinedaten zuschickt, sowie den Boxstatus der PollBox.")
  69.         (default 0)
  70.     )
  71. )
  72. (if(= #copyprg 0)
  73.     (
  74.         (copyfiles (source "Programm") (dest (cat #zielverzeichnis "/" #programm)) (all))
  75.         (if (= #install 1)
  76.             (
  77.                 (set #anzahl(run (cat "stack 20000\nAP_OnlineStatus_link " #programm " " #zielverzeichnis "/" #programm)))
  78.                 (if(< #anzahl 1)
  79.                     (
  80.                         ;Prg-Installation wurde abgebrochen -> kopierte Files löschen
  81.                         (run (cat "delete " #zielverzeichnis "/" #programm "/#?"))
  82.                         (set #copyprg -1)
  83.                     )
  84.                 )
  85.             )
  86.         )
  87.  
  88. ;*******************************************************************
  89. ;  Changefile kopieren und anzeigen
  90. ;*******************************************************************
  91.         (if(= (exists "Programm/ChangesFiles") 2)
  92.             (
  93.                 (copyfiles (source "Programm/ChangesFiles") (dest "bbs:ChangesFiles") (all))
  94.                 (if(= (exists "c:ed") 1)
  95.                     (run (cat "c:ed Programm/changesfiles/" #changefile))
  96.                 )
  97.             )
  98.         )
  99.  
  100.     )
  101. )
  102. ;*******************************************************************
  103. ;  Installation/Update fertig
  104. ;*******************************************************************
  105. (if(= #copyprg 0)
  106.     (
  107.         (set @default-dest #zielverzeichnis)
  108.         (set #done "Update fertig!")
  109.         (exit #done)
  110.     )
  111.     (
  112.         (set @default-dest "")
  113.         (set #done "Installation abgebrochen!")
  114.         (exit #done (quiet))
  115.     )
  116. )
  117.